package net.xdclasss.elasticsearch.model;

import io.searchbox.annotations.JestId;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

@Builder
@Data
@AllArgsConstructor
@NoArgsConstructor
@Document(
        indexName = "nba",
        shards = 1,
        replicas = 1
)
public class NBAPlayer {
    @JestId
    private Integer id;
    @Field(
            type = FieldType.Text
    )
    private String countryEn;
    @Field(
            type = FieldType.Text
    )
    private String country;
    @Field(
            type = FieldType.Text
    )
    private String code;
    @Field(
            type = FieldType.Text
    )
    private String displayAffiliation;
    @Field(
            type = FieldType.Text
    )
    private String displayName;
    @Field(
            type = FieldType.Integer
    )
    private Integer draft;
    @Field(
            type = FieldType.Text
    )
    private String schoolType;
    @Field(
            type = FieldType.Text
    )
    private String weight;
    @Field(
            type = FieldType.Long
    )
    private Integer playYear;
    @Field(
            type = FieldType.Text
    )
    private String jerseyNo;
    @Field(
            type = FieldType.Long
    )
    private Long birthDay;
    @Field(
            type = FieldType.Keyword
    )
    private String birthDayStr;
    @Field(
            type = FieldType.Text
    )
    private String displayNameEn;
    @Field(
            type = FieldType.Text
    )
    private String position;
    @Field(
            type = FieldType.Float
    )
    private Double heightValue;
    @Field(
            type = FieldType.Keyword
    )
    private String playerId;
    @Field(
            type = FieldType.Text
    )
    private String teamCity;
    @Field(
            type = FieldType.Text
    )
    private String teamCityEn;
    @Field(
            type = FieldType.Keyword
    )
    private String teamName;
    @Field(
            type = FieldType.Keyword
    )
    private String teamNameEn;
    @Field(
            type = FieldType.Keyword
    )
    private String teamConference;
    @Field(
            type = FieldType.Keyword
    )
    private String teamConferenceEn;
    @Field(
            type = FieldType.Integer
    )
    private Integer age;
}
